Offset compensation for sense amplifiers

ABSTRACT

A sense amplifier having compensation circuitry is described. The compensation circuitry includes at least one pair of compensation transistors. When compensation is desired, one or a combination of the bulk of the at least one pair of compensation transistors is provided with one or a combination of compensation voltages.

TECHNICAL FIELD

The present disclosure is generally related to sense amplifiers, and,more particularly, to offset compensation for sense amplifiers.

BACKGROUND

A sense amplifier (SA) is used to sense the difference between twosignals at two inputs of the sense amplifier, and amplify the differenceor, commonly stated, amplify the differential signal across the inputs.To sense correctly, a sense margin, which is the minimum differencebetween the two signals, or the minimum differential signal, isrequired.

In many situations, process variation causes two different thresholdvoltages to be present in two transistors that are supposed to be thesame (e.g., two NMOS transistors of a cross latch of an amplifier). Inthat situation, the sense amplifier is said to have an offset at the twoinputs caused by the mismatch of the two transistors. As a result, thesense amplifier favors reading one logic state versus another logicstate, instead of neutrally providing the sensed data. For example, somesense amplifiers, when sensing the differential signal across twoinputs, tend to favor a high logic level, (e.g., a High) while someother sense amplifiers tend to favor a low logic level (e.g., a Low). Asense amplifier tending to favor a High quickly provides the High as theread data at the output when the actual High data is sensed, but slowlyprovides a Low as the read data at the output when the actual Low datais sensed. Similarly, a sense amplifier tending to favor a Low quicklyprovides the Low when the actual Low data is sensed, but slowly providesa High when the actual High data is sensed.

In effect, because of the process variation, the mismatch manifests asan additional offset, which causes the sense amplifier to require alarger sense margin to correctly sense the data. In applications whereone sense margin is used for many amplifiers, a larger value for thesense margin is utilized so that a very high percentage, or all, of thesense amplifiers function correctly. As the large sense margin is used,the time required for the differential signal to develop increases,making the overall memory access speed slower.

BRIEF DESCRIPTION OF THE DRAWINGS

The details of one or more embodiments of the disclosure are set forthin the accompanying drawings and the detailed description below. Otherfeatures and advantages will be apparent from the detailed description,drawings, and claims.

FIG. 1 is a diagram of a sense amplifier having compensation circuitry,in accordance with some embodiments.

FIG. 2 is a diagram of a circuit illustrating a first mechanism tocompensate for the offset of the sense amplifier in FIG. 1, inaccordance with some embodiments.

FIG. 3 is a diagram of a circuit illustrating a second mechanism tocompensate for the offset of the sense amplifier in FIG. 1, inaccordance with some embodiments.

FIG. 4 is a flow chart illustrating a method of compensating the offsetfor a plurality of the sense amplifiers used in a memory, in accordancewith some embodiments.

FIG. 5 is a diagram of a sense amplifier having compensation circuitry,in accordance with some further embodiments.

Like reference symbols in the various drawings indicate like elements.

DETAILED DESCRIPTION

Embodiments, or examples, illustrated in the drawings are disclosedbelow using specific language. It will nevertheless be understood thatthe embodiments and examples are not intended to be limiting. Anyalterations and modifications in the disclosed embodiments, and anyfurther applications of the principles disclosed in this document arecontemplated as would normally occur to one of ordinary skill in thepertinent art. Reference numbers may be repeated throughout theembodiments, but they do not require that feature(s) of one embodimentapply to another embodiment, even if they share the same referencenumber.

Some embodiments can have one or a combination of the following featuresand/or advantages. The re-offset voltage provided to the bulks of thecompensation transistors reduces the sense margin. As a result, thememory access time is improved.

Exemplary Sense Amplifiers with Compensation Mechanisms

FIG. 1 is a diagram of a sense amplifier (SA) 100, in accordance withsome embodiments. In some embodiments, sense amplifier 100 is used inmemory arrays, but SA 100 can be used in other circuits where a smallsignal difference is to be amplified, including, for example, an IOinterface. In some memory applications, multiple memory cells on acolumn share the same amplifier.

SA 100 senses a high logic level (e.g., a High) at output Out when thevoltage value at input SAIN_H is greater than the voltage value at inputSAIN_L. Similarly, SA 100 senses a low logic level (e.g., a Low) atoutput Out when the voltage value at input SAIN_H is lower than thevoltage value at input SAIN_L. Transistor N3 operates as a switch andserves as a current path for SA to be turned on/off. For example, whensignal SAE is applied with a High, transistor N3 turns on, and providesa current path for SA 100 to turn on. In contrast, when signal SA isapplied with a Low, transistor N3 turns off, and SA 100 turns offbecause there is no current path.

In some embodiments, for various reasons, including device manufacturingprocess variations, transistor N1 and transistor N2 are not exactly thesame (i.e., mismatched). As a result, transistor N1 has a thresholdvoltage (e.g., threshold voltage Vthn1) different from that oftransistor N2 (e.g., threshold voltage Vthn2), which causes an offset atinputs SAIN_H and SAIN_L. Because of the mismatch in the transistors, orthe offset, at inputs SAIN_H and SAIN_L, sense amplifier 100 favorsreading a logic state versus another logic state, instead of neutrallyproviding the sensed data. For example, if voltage Vthn1 is greater thanvoltage Vthn2, then SA 100 favors reading a Low on node SAIN_H when nodeSAIN_H serves as an output. If voltage Vthn1 is less than voltage Vthn2,then SA 100 favors reading a High on node SAIN_H when node SAIN_H servesas an output. For illustration, voltage ΔVth represents the differencebetween threshold voltage Vthn1 and threshold voltage Vthn2. VoltageΔVth is positive if voltage Vthn1 is greater than voltage Vthn2, andvoltage ΔVth is negative if voltage Vthn1 is less than voltage Vthn2.Further, voltage ΔInput represents the offset at inputs SAIN_H andSAIN_L corresponding to voltage ΔVth. In some embodiments, mechanismsare provided to compensate (e.g., reduce, cancel, re-offset, etc.) theeffect of the threshold voltage offset (e.g., the voltage difference)ΔVth, and after the threshold offset ΔVth is re-offset, the inputvoltage offset caused by the threshold offset is reduced or canceled(e.g., re-offset). For simplicity of illustration, reducing orre-offsetting the offset described in this document could cancel theoffset altogether.

PMOS transistors PO1 and PO2 are commonly called compensationtransistors, and serve to re-offset (e.g., cancel, reduce, compensate,etc.) the offset caused by the mismatch between transistors N1 and N2.When compensation is desired, one or a combination of the bulk oftransistor PO1 and PO2 is provided with one or a combination of bulkre-offset voltages (e.g., Vrob, Vrob1, Vrob2 illustrated below) thatcompensates for the mismatch. Alternatively stated, the bulk re-offsetvoltage(s) cancels the input offset at the corresponding input SAIN_Hand/or SAIN_L. In some embodiments, the gates of transistors PO1 and PO2are coupled together and to ground (e.g., Low) so that transistors PO1and PO2 are turned on for re-offsetting. In the following explanation,for ease of discussion, when one re-offset voltage is provided to thebulk of one PMOS transistor (e.g., transistor PO2), the bulk of theother PMOS transistor (e.g., transistor PO1) remains the same (e.g., atvoltage Vdd).

In some embodiments, if voltage Vthn1 is greater than voltage Vthn2(e.g., voltage ΔVth is positive, and sense amplifier 100 favors readinga Low), a negative bulk re-offset voltage Vrob is provided to the bulkof transistor PO2, which cancels the offset at inputs SAIN_L and SAIN_Hthat corresponds to the threshold voltage difference ΔVth. But ifvoltage Vthn1 is less than voltage Vthn2 (e.g., voltage ΔVth isnegative, and sense amplifier 100 favors reading a Low), a negative bulkre-offset voltage Vrob is provided to the bulk of transistor PO1, whichalso cancels the offset at inputs SAIN_L and SAIN_H corresponding to thethreshold voltage difference ΔVth. Once voltage Vrob is provided to thebulk of transistor PO2 or transistor PO1, the threshold voltage of thecorresponding transistor (e.g., voltage Vthp2 or voltage Vthp1) changes,which re-offsets the offset caused by the mismatch (e.g., the differencein the threshold voltages) between transistors N1 and N2.

In some embodiments, the mismatch between transistors N1 and N2 causingthe offset exists after sense amplifier 100 is manufactured, and thedifference in the threshold voltage ΔVth is identified by a Monte Carlossimulation. Based on the identified ΔVth, the re-offset voltage Vrob isdetermined and provided to the bulk of the corresponding transistor PO1or PO2.

In some embodiments, a plurality of sense amplifiers (e.g., senseamplifiers 100) is used in a circuit (e.g., in a memory array), and theminimum sense margin (e.g., Smin) for the plurality of sense amplifiersis known. For example, the minimum sense margin Smin is the mean of thesense margins of all sense amplifiers plus three sigma. The senseamplifiers are then configured to sense some known data based on theknown (i.e., pre-determined) sense margin. In some embodiments relatedto a memory array, a built-in self test (BIST) is used to test the senseamplifiers used in the memory array. For example, for each senseamplifier the minimum read margin is set for the sense amplifier, theBIST is invoked for the sense amplifier to test itself using a specificinput data (e.g., a Low or a High). The test result is compared againstthe expected test data from which the sense amplifiers are classifiedinto a group of sense amplifiers favoring reading a High (e.g., group I)and/or another group of sense amplifiers favoring reading a Low (e.g.,group II).

For example, sense amplifiers that are supposed to provide a Low aftersensing, but provide the failed data, reveal that the sense amplifiersfavor reading a High and thus are classified into group I. Similarly,sense amplifiers that are supposed to provide a High after sensing butfailed the sensing reveal that those amplifiers favor reading a Low andare classified into group II. For each sense amplifier in group I, acorresponding positive bulk re-offset voltage Vrob is provided to thebulk of transistor PO2, which, in effect, provides the input re-offsetto input SAIN_L. At the same time, the bulk of each transistor PO2 ingroup I remains unchanged, e.g., at voltage Vdd. Similarly, for eachsense amplifier in group II, a corresponding bulk re-offset voltage Vrobis provided to the bulk of transistor PO1, which, in effect, providesthe input re-offset to input SAIN_H. At the same time, the bulk of eachtransistor PO1 in group II remains unchanged, e.g., at voltage Vdd.

In some embodiments, re-offset voltage Vrob is calculated based on thedifference in the threshold voltage of transistor N1 (e.g., Vthn1) andthat of transistor N2 (e.g., Vthn2), e.g., voltage ΔVt. If voltage ΔVtis 0, then the offset is 0, and re-offset voltage Vrob is 0 V. But ifvoltage ΔVt is not 0, voltage ΔVt is used to generate the difference inthreshold voltages of transistors PO1 and PO2 (e.g., ΔVtp) to re-offsetthe voltage difference ΔVt of transistors N1 and N2, by, for example,changing one or a combination of the threshold voltage of transistorsPO1 and PO2. For example, if ΔVt is 100 mV, then the threshold voltageof transistor PO1 (e.g., voltage Vthpo1) is configured to change by 100mV, while the threshold voltage of transistor PO2 (e.g., voltage Vthpo2)remains unchanged, or voltage Vthpo2 of transistor PO2 is configured tochange by −100 mV while voltage Vthpo1 of transistor PO1 remainsunchanged. Alternatively, voltage Vthpo1 is configured to change by 40mV, 50 mV, or 60 mV, and voltage Vthpo2 is configured to change by −60mV, −50 mV, and −40 mV, etc., respectively. For illustration, thethreshold voltage of transistors PO2 is adjusted. In other words,threshold voltage Vthpo2 is changed by −ΔVtp where ΔVtp=ΔVt. In someembodiments, ΔVtp is generated by providing negative voltage Vrob to thebulk of transistor PO2. Further, voltage Vrob is calculated based on theequation:

V _(TN) =V _(TO)+γ(√{square root over (V _(SB)+2φ_(F))}−√{square rootover (2φ_(F))})

where V_(TN) is the threshold voltage of transistor PO2 when thesubstrate bias is present, V_(SB) is the source-to-body substrate bias(e.g., Vrob), 2φ_(F) is the surface potential, and V_(TO) is thethreshold voltage for zero substrate bias and γ is the body effectparameter.

FIG. 1 is illustrated with the transistor PO1 coupled betweentransistors P1 and N1, and transistor PO2 coupled between transistors P2and N2. Various embodiments are not so limited. Transistor PO1 can becoupled between voltage Vdd and transistor P1 while transistor PO2 canbe coupled between voltage Vdd and transistor P2. The sign of re-offsetvoltage Vrob, however, is changed accordingly, as recognizable bypersons of ordinary skilled in the art. For example, when voltage Vthn1is greater than voltage Vthn2 (e.g., voltage ΔVth is positive), acorresponding positive re-offset voltage Vrob is applied at the bulk oftransistor PO2, and when voltage Vthn2 is less than voltage Vthn2 (e.g.,voltage ΔVth is negative), a corresponding positive re-offset voltageVrob is applied at the bulk of transistor PO1, etc.

Exemplary Offset Circuits

FIG. 2 is a diagram of a circuit 200 illustrating offset compensationfor SA 100, in accordance with some embodiments. In this illustration,the bulk of one transistor (e.g., transistor PO1 or PO2) remains thesame (e.g., at voltage Vdd) while the bulk of the other transistor isprovided with bulk re-offset voltage Vrob. In some embodiments, the bulkof PMOS transistors without a re-offset is set at voltage Vdd, and thebulk of the transistor receiving the offset is provided with voltageVdd+Vrob to provide the re-offset voltage Vrob. For example, if there-offset is for transistor PO2, then the bulk of transistor PO2 isprovided with Vdd+Vrob, while the bulk of transistor PO1 remains thesame at voltage Vdd. Similarly, if the re-offset is to transistor PO1,then the bulk of transistor PO1 is provided with Vdd+Vrob, while thebulk of transistor PO2 remains the same at voltage Vdd. In someembodiments, re-offsetting to the bulk of transistor PO2 with are-offset voltage value Vrob results in a re-offset at input SAIN_L witha corresponding voltage value Vroi. Similarly, re-offsetting to the bulkof transistor PO1 with a re-offset voltage value results in a re-offsetat input SAIN_H with a corresponding voltage value Vroi.

In FIG. 2, when signal SET is activated (e.g., applied with a High),NMOS transistor N21 turns on, which pulls node NO21, which is the drainof transistor N21, to ground (e.g., Low). As a result, transistor PPG1is turned on, and voltage Vdd+Vrob is passed through transistor PPG1 tothe bulk of transistor PO2. In effect, the bulk of transistor PO2 isprovided with a re-offset voltage value of Vrob. Node NO21 pulled lowalso causes transistor P22 to turn on, which transfers voltage Vdd atthe source of transistor P22 to the drain of transistor P22 or to thebulk of transistor PO1.

Similarly, when signal RESET is activated (e.g., applied with a High),NMOS transistor N22 turns on, which pulls node NO22, which is the drainof transistor N22, to ground (e.g., Low). As a result, transistor PPG2is turned on, and voltage Vdd+Vrob is passed through transistor PPG2 tothe bulk of transistor PO1. In effect, the bulk of transistor PO1 isprovided with a re-offset voltage value of Vrob. Node NO22 being Lowalso causes transistor P21 to turn on, which transfers voltage Vdd atthe source of transistor P21 to the drain of transistor P21 or to thebulk of transistor PO2.

Latch Ltch stores the value passed through transistors PPG1 and PPG2 atnodes NO21 and NO22, respectively.

In the above illustration, the bulk of one transistor (e.g., transistorPO1 or PO2) is re-offset and the bulk of the other transistor remainsthe same. In some embodiments, the bulks of both transistors PO1 and PO2are re-offset. FIG. 3 is a diagram of a circuit 300 illustratingre-offsetting to the bulk of both transistors PO1 and PO2. In thisillustration, the bulk of transistor PO1 is re-offset with a firstvalue, e.g., voltage Vrob1, by a sub-circuit 300A, and the bulk oftransistor PO2 is re-offset with a second value, e.g., voltage Vrob2, bya sub-circuit 300B. Circuits 300A and 300B include similar componentsand operate in the same manner except circuit 300A is used to re-offsetthe bulk of transistor PO1 while circuit 300B is used re-offset the bulkof transistor PO2. Further, a circuit 300A or 300B operatessubstantially the same as circuit 200. For simplicity, only one circuit,e.g., circuit 300A is described, and the operation of the other circuit,e.g., circuit 300B, can be understood by a person of ordinary skill inthe art. When there is no compensation or re-offset, signal SET1 isactivated, transistor PPG1 is turned on and voltage Vdd is passed to thebulk of transistor PO1. But when a re-offset value, e.g., voltage Vrob1is desired, signal RESET1 is activated, transistor PPG2 is activated,and voltage Vdd+Vrob1 is passed to the bulk of transistor PO1. Ineffect, the bulk of transistor PO1 is re-offset with voltage Vrob1.

In circuit 300, voltage Vrob1 or voltage Vrob2 is negative or positive,and the total re-offset by voltage Vrob1 to the bulk of transistor PO1and voltage Vrob2 to the bulk of transistor PO2 is to reduce the effectof the mismatch between transistor N1 and N2.

Exemplary Method of Re-Offsetting a Plurality of Sense Amplifiers

FIG. 4 is a flowchart illustrating a method 400 of re-offsetting aplurality of sense amplifiers used in a memory array, in accordance withsome embodiments. Method 400, however, can be used for sense amplifiersin other circuits.

In step 405, re-offset voltage Vrob is set to 0 V.

In step 408, re-offset voltage Vrob is applied to all sense amplifiers.

In step 410, a BIST is invoked for the sense amplifiers to sense andverify the sense results of the sense amplifiers.

In step 415, if all sense amplifiers pass, the applied voltage Vrob isidentified as the desired re-offset voltage in step 417. If, however,any of the amplifiers fails, the failed amplifiers are grouped into afirst group favoring reading a High (e.g., group I) and/or a secondgroup favoring reading a Low (e.g., group II) in step 418.

In step 420, re-offset voltage Vrob is changed (e.g., is decreased, forexample, by −100 mV, in some embodiments), and the new re-offset voltage(e.g., voltage Vrobn) is applied in step 410, in accordance with theidentified groups. For example, for amplifiers in group I, voltage Vrobnis applied to the bulk of transistor PO1 while, for amplifiers in groupII, voltage Vrobn is applied to the bulk of transistors PO2. When allamplifiers pass (e.g., in step 415), a first re-offset voltage (e.g.,voltage Vrob1) is identified for group I, and a second re-offset voltage(e.g., voltage VrobII) is identified for group II, in step 417.

In flow chart 400, a sequential search (e.g., voltage Vrobn keepsdecreasing) is used for illustration. However, other searches, includinga binary search are within the scope of various embodiments.

Exemplary Sense Amplifier with Compensation Mechanisms—Some FurtherEmbodiments

FIG. 5 is a diagram of a sense amplifier (SA) 500 having offsetcompensation circuitry, in accordance with some further embodiments.Compared with SA 100, SA 500 includes two NMOS transistors NO1 and NO2that replace PMOS transistors PO1 and PO2, respectively. The gates oftransistors NO1 and NO2, however, are coupled to voltage Vdd (e.g., aHigh) plus Vthn, the threshold voltage of transistors NO1 and NO2, sothat transistors NO1 and NO2 are turned on for re-offsetting. Further,the drains of transistors NO1 and NO2 are coupled to the drains oftransistors P1 and P2, respectively, and the source of transistors NO1and NO2 are coupled to the drains of transistor N1 and N2, respectively.

The re-offset operation of transistors NO1 and NO2 is substantially thesame as that of transistors PO1 and PO2. For example, when voltage Vthn1is greater than voltage Vthn2 (e.g., voltage ΔVth is positive), acorresponding positive re-offset voltage Vrob is applied at the bulk oftransistor NO2, and when voltage Vthn2 is less than voltage Vthn2 (e.g.,voltage ΔVth is negative), a corresponding positive re-offset voltageVrob is applied at the bulk of transistor NO1, etc. Different techniques(e.g., having one or two re-offset voltages, negative and/or positivere-offset voltages, etc.) applicable to SA 100 are applicable to SA 500as would be recognizable by a person of ordinary skill in the art.

FIG. 5 is illustrated with the transistor NO1 coupled betweentransistors P1 and N1, and transistor NO2 coupled between transistors P2and N2. Various embodiments are not so limited. Transistor NO1 can becoupled between transistor N1 and transistor N3 while transistor NO2 canbe coupled between transistor N2 and transistor N3. The sign ofre-offset voltage Vrob, however, is changed accordingly, as recognizableby persons of ordinary skilled in the art. For example, when voltageVthn1 is greater than voltage Vthn2 (e.g., voltage ΔVth is positive), acorresponding negative re-offset voltage Vrob is applied at the bulk oftransistor NO2, and when voltage Vthn2 is less than voltage Vthn2 (e.g.,voltage ΔVth is negative), a corresponding negative re-offset voltageVrob is applied at the bulk of transistor NO1, etc.

In the above illustration (e.g., FIG. 1 and FIG. 5), one pair oftransistors (e.g., the pair of transistor PO1 and PO2 or the pair oftransistor NO1 and NO2) is used. Combinations of pairs of transistorsare within the scope of various embodiments, and are recognizable bypersons of ordinary skill in the art. For example, a pair of NMOStransistors NO1 and NO2 can be added to circuit 100 by having transistorNO1 coupled between transistor PO1 and transistor N1 or betweentransistor N1 and transistor N3, and transistor NO2 coupled betweentransistor PO2 and transistor N2 or between transistor N2 and transistorN3. Similarly, a pair of PMOS transistors PO1 and PO2 can be added tocircuit 500 by having transistor PO1 coupled between transistor P1 andvoltage Vdd node and transistor PO2 coupled between transistor P2 andvoltage Vdd node, etc.

A number of embodiments have been described. It will nevertheless beunderstood that various modifications may be made without departing fromthe spirit and scope of the disclosure. For example, the varioustransistors being shown as a particular dopant type (e.g., NMOS andPMOS) are for illustration purposes, embodiments of the disclosure arenot limited to a particular type, but the dopant type selected for aparticular transistor is a design choice and is within the scope ofvarious embodiments. The logic level (e.g., low or high) of the varioussignals used in the above description is also for illustration purposes,various embodiments are not limited to a particular level when a signalis activated and/or deactivated, but, rather, selecting such a level isa matter of design choice. In some embodiments, a source/drain is usedfor either a source or a drain of a transistor.

Some embodiments are described as having one bulk voltage re-offsetapplied at a bulk of one transistor PO1 or PO2, and some embodiments aredescribed as having two bulk re-offset voltages applied at the bulks ofboth transistors PO1 and PO2. Various embodiments of the invention arenot limited to a particular mechanism of re-offsetting by using one ortwo bulk re-offset voltages. Selecting one or two re-offset voltages isa design choice and is within the scope of the various embodiments. Invarious embodiments, when a re-offset is applied, the re-offset value iseither positive or negative and can be applied to a correspondingtransistor. For example, in the above illustration, when voltage Vthn1is greater than voltage Vthn2, a negative re-offset voltage Vrob isapplied to the bulk of transistor PO2. Alternatively, a positivere-offset of the same value can be applied to the bulk of transistorPO1. Various embodiments are not limited to a positive or a negativevalue, nor applying to one particular transistor. For example, when abulk re-offset voltage corresponding to voltage ΔVth is identified, there-offset voltage can be applied to a particular transistor, or the samenegative offset can be applied to the other transistor, or the bulkre-offset can be split into two and applied to both transistors. Forexample, the bulk re-offset is Vrob identified, from which ½ Vrob can beapplied to the bulk of a transistor (e.g., transistor PO1) and −½ Vrobcan be applied to the bulk of the other transistor (e.g., transistorPO2), etc.

Some embodiments regard an amplifier that comprises a first PMOStransistor having a first PMOS drain, a first PMOS gate, and a firstPMOS source; a second PMOS transistor having a second PMOS drain, asecond PMOS gate, and a second PMOS source; a first NMOS transistorhaving a first NMOS drain, a first NMOS gate, and a first NMOS source; asecond NMOS transistor having a second NMOS drain, a second NMOS gate,and a second NMOS source; a first compensation transistor having a firstcompensation drain, a first compensation gate, a first compensationsource, and a first compensation bulk; a second compensation having asecond compensation drain, a second compensation gate, a secondcompensation source, and a second compensation bulk. The firstcompensation transistor is coupled to the first PMOS drain and the firstNMOS drain. The second compensation transistor is coupled to the secondPMOS drain and the second NMOS drain. The second PMOS gate, the secondNMOS gate, and the first NMOS drain are coupled together, and serve as afirst data input for the sense amplifier. The first PMOS gate, the firstNMOS gate, and the second NMOS drain are coupled together, and serve asa second data input for the sense amplifier. The first compensationtransistor bulk serves as a first compensation input for the senseamplifier and the second compensation transistor bulk serves as a secondcompensation input for the sense amplifier.

Some embodiments regard a method of compensating a sense amplifier. Themethod includes the following steps: determining whether there is amismatch between a first transistor N1 of the amplifier and a secondtransistor N2 of the amplifier; and applying a compensation voltagevalue to one or a combination of a first bulk of a first compensationtransistor PO1 of the amplifier and a second bulk of a secondcompensation transistor PO2 of the amplifier, if there is the mismatchand while the first compensation transistor and the second compensationtransistor are on. The first compensation transistor PO1 is coupledbetween the first transistor N1 and a third transistor P1 of theamplifier. The second compensation transistor PO2 is coupled between thesecond transistor N2 and a fourth transistor P2 of the amplifier. A gateof the second transistor and a gate of the fourth transistor are coupledtogether and form a first data input for the amplifier. A gate of thethird transistor and a gate of the first transistor are coupled togetherand form a second data input for the amplifier. Applying thecompensation voltage value causes a reduction in a voltage differencebetween a first threshold voltage of the first transistor and a secondthreshold voltage of the second transistor.

Some embodiments regard a method of re-offsetting a plurality ofamplifier. The method includes testing the plurality of amplifiers basedon a re-offset value at bulks of compensation transistors of theplurality of amplifiers; identifying a first group of first amplifiersof the plurality of amplifiers favoring reading a first logic leveland/or a second group of second amplifiers of the plurality ofamplifiers favoring reading a second logic level different from thefirst logic level, based on results of the testing step; changing there-offset value to a new re-offset value; re-offsetting the first groupof first amplifiers and/or the second group of second amplifiers basedon the new re-offset value; and re-testing the first group of firstamplifiers and the second group of second amplifiers.

The above methods show exemplary steps, but they are not necessarilyperformed in the order shown. Steps may be added, replaced, changedorder, and/or eliminated as appropriate, in accordance with the spiritand scope of disclosed embodiments.

1. A sense amplifier comprising: a first PMOS transistor having a firstPMOS drain, a first PMOS gate, and a first PMOS source; a second PMOStransistor having a second PMOS drain, a second PMOS gate, and a secondPMOS source; a first NMOS transistor having a first NMOS drain, a firstNMOS gate, and a first NMOS source; a second NMOS transistor having asecond NMOS drain, a second NMOS gate, and a second NMOS source; a firstcompensation transistor having a first compensation drain, a firstcompensation gate, a first compensation source, and a first compensationbulk; and a second compensation transistor having a second compensationdrain, a second compensation gate, a second compensation source, and asecond compensation bulk, wherein the second PMOS gate, the second NMOSgate, and the first NMOS drain are coupled together, and serve as afirst data input for the sense amplifier; the first PMOS gate, the firstNMOS gate, and the second NMOS drain are coupled together, and serve asa second data input for the sense amplifier; the first compensationtransistor is coupled between a power supply voltage node and the firstPMOS transistor or between the first PMOS transistor and the first NMOStransistor or between the first NMOS transistor and a first node; thesecond compensation transistor is coupled between the power supplyvoltage node and the second PMOS transistor or between the second PMOStransistor and the second NMOS transistor or between the second NMOStransistor and the first node; and the first compensation bulk serves asa first compensation input for the sense amplifier and the secondcompensation bulk serves as a second compensation input for the senseamplifier.
 2. The amplifier of claim 1, wherein: the first compensationtransistor and the second compensation transistor are PMOS transistors;the first compensation transistor is coupled between the power supplyvoltage node and the first PMOS transistor or between the first PMOStransistor and the first NMOS transistor; and the second compensationtransistor is coupled between the power supply voltage node and thesecond PMOS transistor or between the second PMOS transistor and thesecond NMOS transistor.
 3. The amplifier of claim 1, wherein: the firstcompensation transistor and the second compensation transistor are NMOStransistors; the first compensation transistor is coupled between thefirst PMOS transistor and the first NMOS transistor or between the firstNMOS transistor and the first node; and the second compensationtransistor is coupled between the second PMOS transistor and the secondNMOS transistor or between the second NMOS transistor and the firstnode.
 4. The amplifier of claim 1, wherein the first compensation inputis configured to receive a first compensation value and the secondcompensation input is configured to receive a second compensation value,based on one or a combination of: a voltage difference between a firstNMOS threshold voltage of the first NMOS transistor and a second NMOSthreshold voltage of the second NMOS transistor; a voltage differencebetween the first data input of the amplifier and the second data inputof the amplifier; and first data sensed by the amplifier based on seconddata fed to the amplifier.
 5. The amplifier of claim 4, wherein thefirst compensation value or the second compensation value is zero. 6.The amplifier of claim 1 configured to satisfy at least one of thefollowing conditions: the second compensation input is configured toreceive a negative compensation voltage when a first NMOS thresholdvoltage of the first NMOS transistor is greater than a second NMOSthreshold voltage of the second NMOS transistor, and the firstcompensation input is configured to receive a negative compensationvoltage when the first NMOS threshold voltage of the first NMOStransistor is less than the second NMOS threshold voltage of the secondNMOS transistor.
 7. The amplifier of claim 1 configured to satisfy atleast one of the following conditions: the first compensation input isconfigured to receive a positive compensation voltage, when a first NMOSthreshold voltage of the first NMOS transistor is greater than a secondNMOS threshold voltage of the second NMOS transistor, and the secondcompensation input is configured to receive a positive compensationvoltage, when the first NMOS threshold voltage of the first NMOStransistor is less than the second NMOS threshold voltage of the secondNMOS transistor.
 8. The amplifier of claim 1, wherein one or acombination of the first compensation input and the second compensationinput is configured to receive a compensation voltage to reduce avoltage difference between a first threshold voltage of the first NMOStransistor and a second threshold voltage of the second NMOS transistor.9. A method for compensating a sense amplifier, comprising: turning on afirst compensation transistor and a second compensation transistor ofthe sense amplifier; and applying a compensation voltage value to one ora combination of a first bulk of the first compensation transistor and asecond bulk of the second compensation transistor, if there is amismatch between a first transistor of the amplifier and a secondtransistor of the amplifier; and wherein: the first compensationtransistor is electrically coupled to a first drain or a first source ofthe first transistor; the second compensation transistor is electricallycoupled to a second drain or a second source the second transistor; agate of a second transistor of the amplifier and a gate of the fourthtransistor are coupled together and form a first data input for theamplifier; and a gate of a third transistor of the amplifier and a gateof the first transistor are coupled together and form a second datainput for the amplifier; and applying the compensation voltage valuecauses a voltage change between a first threshold voltage of the firstcompensation transistor and a second threshold voltage of the secondcompensation transistor.
 10. The method of claim 9 further comprisingdetermining if there is a mismatch by having the sense amplifier providefirst sensed data based on second data fed to the sense amplifier. 11.The method of claim 10, wherein there is a mismatch if the first senseddata differs from the second fed data.
 12. The method of claim 9,wherein whether there is the mismatch is determined by using a built-inself test to determine if the amplifier provides expected data.
 13. Themethod of claim 9, wherein whether there is the mismatch is determinedby determining whether there is the voltage difference between the firstthreshold voltage and the second threshold voltage.
 14. The method ofclaim 9, wherein applying a compensation voltage value to one or acombination of the first bulk and the second bulk includes applying apositive compensation voltage value to the second bulk while maintainingthe first bulk at a same first bulk voltage level or applying a negativecompensation voltage value to the first bulk and maintaining the secondbulk at a same second bulk voltage level, if a voltage threshold of thefirst transistor is greater than a voltage threshold of the secondtransistor; or applying a positive compensation voltage value to thefirst bulk and maintaining the second bulk at the same second bulkvoltage level or applying a negative compensation voltage value to thesecond bulk and maintaining the first bulk at the same first bulkvoltage level, if the voltage threshold of the first transistor is lessthan the voltage threshold of the second transistor.
 15. The method ofclaim 9, wherein: the first transistor and the second transistor areNMOS transistors; the third transistor and the fourth transistor arePMOS transistors; and the first compensation transistor and the secondcompensation transistor are NMOS transistors or PMOS transistors.
 16. Amethod of re-offsetting a plurality of amplifiers, comprising: testingthe plurality of amplifiers based on a re-offset value at bulks ofcompensation transistors of the plurality of amplifiers; identifying afirst group of first amplifiers of the plurality of amplifiers favoringreading a first logic level and/or a second group of second amplifiersof the plurality of amplifiers favoring reading a second logic leveldifferent from the first logic level, based on results of the testingstep; changing the re-offset value to a new re-offset value;re-offsetting the first group of first amplifiers and/or the secondgroup of second amplifiers based on the new re-offset value; andre-testing the first group of first amplifiers and the second group ofsecond amplifiers.
 17. The method of claim 16, wherein: re-offsettingthe first group of first amplifiers includes, for each first amplifierin the first group of first amplifiers, changing at least one firstvoltage value at least one first bulk of at least one first compensationtransistor of the each first amplifier; and re-offsetting the secondgroup of second amplifiers includes, for each second amplifier in thesecond group of second amplifiers, changing at least one second voltagevalue at least one second bulk of at least one second compensationtransistor of the each second amplifier.
 18. The method of claim 16,wherein: identifying the first group of the first amplifiers includesproviding first data to the first amplifiers and identifying the firstamplifiers that fail; identifying the second group of the secondamplifiers includes providing second data to the second amplifiers andidentifying the second amplifiers that fail; and the first data is ofopposite logic level from the second data.
 19. The method of claim 16,wherein a pair of compensation transistors of the compensationtransistors is coupled to a pair of transistors of an amplifier of theplurality of amplifiers that has different threshold voltage values. 20.The method of claim 19, wherein the pair of transistors of an amplifierof the plurality of amplifiers that has different threshold voltagevalues is NMOS transistors and the pair of compensation transistors areNMOS or PMOS transistors.